home *** CD-ROM | disk | FTP | other *** search
/ Night Owl 6 / Night Owl's Shareware - PDSI-006 - Night Owl Corp (1990).iso / 002a / zzt.zip / LANG.HLP < prev    next >
Text File  |  1990-01-26  |  3KB  |  93 lines

  1. $ZZT-OOP
  2. $Programming Language
  3.  
  4. Table of contents:
  5. !ov;Overview.
  6. !-langtut;Tutorial.
  7. !-langref;Reference manual.
  8.  
  9. :Ov;Overview.
  10.  
  11.      ZZT provides a special type of
  12. creature, the Object, that can be made to
  13. interact with the player and the
  14. environment by using a small object-
  15. oriented command language.  Objects
  16. are very versatile, and can move, talk and
  17. bargain with the player, and communicate
  18. with other Objects.
  19.  
  20.      To put an Object on the playing
  21. field, type F2 O.  Next, you can choose a
  22. character to represent the Object.
  23. Finally, you can enter a program to
  24. control it.
  25.  
  26.      To change an Object's program, move
  27. the cursor to the Object and press Enter.
  28.  
  29.  
  30. $How they work.
  31.  
  32.      During game play, the Objects are
  33. actively controlled by their associated
  34. programs.  Commands are executed in tempo
  35. with the game.  Usually, an Object is
  36. updated 4 or 5 times per second, and
  37. several commands are executed on each
  38. update.
  39.  
  40.      Objects communicate with each other
  41. and with the environment by sending and
  42. receiving messages.  Understanding ZZT-OOP
  43. is often difficult because it is possible
  44. to have many objects operating at the same
  45. time, and each object can interact with
  46. any other object at any time.
  47.  
  48. $Interaction.
  49.  
  50.      A programmable creature can put
  51. flashing one-line messages at the bottom
  52. of the screen.  It can also put multi-
  53. line scrolling messages on the screen. 
  54. These messages can be interactive, so that
  55. the player can pick choices from a menu.
  56.  
  57.      Objects can also move, shoot, and
  58. interact with other objects.
  59.  
  60. $Messages - What are they?
  61.  
  62.      ZZT's programming language is object-
  63. oriented, meaning that a program's flow of
  64. execution is controlled by sending and
  65. receiving messages.  Whenever an important
  66. event occurs, a message is sent to an
  67. object.  This causes the program to
  68. execute specific instructions to handle
  69. the event.  Messages can come from two
  70. sources:  from other programmable creatues
  71. and from the game itself.
  72.  
  73.      For example, whenever the player
  74. touches an object, that object receives
  75. the message, "TOUCH".  The object can
  76. then act on the message, for example by
  77. greeting the player or attacking.  Or,
  78. the object can ignore the message.
  79.  
  80.      Similarly, objects can communicate
  81. with each other by exchanging messages.
  82. For example, a board contains a "BUTTON"
  83. object and a "GATE" object.  The player
  84. touches the button.  Upon being touched,
  85. the button sends the message "OPEN" to
  86. the gate object.  The gate, upon
  87. receiving this message, moves aside.
  88.  
  89.      The first step to learning ZZT-OOP is
  90. seeing actual programs with explainations:
  91.  
  92. !-langtut;ZZT-OOP Tutorial.
  93.